import { getProvinces } from '../utils/index.js'
import $ from 'jquery'
getProvinces().then((res) => {
  const ul = $('.provinces')
  for (const p of res) {
    const li = $('<li>').appendTo(ul)
    const a = $('<a>').text(p.simpleName).appendTo(li)
    a.prop('href', `detail.html?name=${p.areaName}&id=${p.id}`)
  }
})
